package model;

//NEED TO FIX CODE BELOW

import java.awt.event.KeyEvent;

public class log {
	private int posX;
	private int posY;
	private int velocityX;
	//private int point; //score value
	private int height; //in pixels
	private int width;
	private String word;
	//private enum colour {BROWN, GREEN, YELLOW, BLUE, ORANGE}; //how to use enumeration??
	
	public log(String word) {
		this.word = word;
	}
	
	//This needs to be fixed
	
	public void move(double time) {
		if (posX < -100 && velocityX <0) {
			posX = 1000;
		}
		else if (posX >= 1100 && velocityX >0) {
			posX = -100;
		}
		
		this.posX += velocityX * time;
	}
	
	public void setDim(int w, int h) {
		this.width = w;
		this.height = h;
	}
	
	public void setPos(int x, int y) {
		this.posX = x;
		this.posY = y;
	}
	
	public void setVelocityX(int vx) {
		this.velocityX = vx;
	}
	
	public int getVelocityX(){
		return velocityX;
	}
	//accessors
	
	public String getWord() {
		return word;
	}
	
	public int getPosX() {
		return posX;
	}
	
	public int getPosY() {
		return posY;
	}
	
	public int getHeight() {
		return height;
	}
	
	public int getWidth() {
		return width;
	}

}
